<template>
  <div>
    {{ form.name }}
    {{ name }}
    <button @click='getvalues'>click</button>
  </div>
</template>

<script>
import axios from '../http/axios'
import {reactive, ref,onMounted} from 'vue'

export default {
  setup() {
    let form = reactive({'name': 'a', 'pass': '34'})
    let name = ref('234')
    const getvalues = () => {
      form.name = 'abc'
      name.value = 'ttt'
      axios('test', 'get').then(res => {
        console.log(res.code)
      })
      onMounted(()=>{
        getvalues
      })
    }
    return {
      form,
      getvalues,
      name
    }


  }
}
</script>

<style scoped>

</style>